cmake_minimum_required(VERSION 2.8)

message("-- Project: stdcrt_test")

file(GLOB test_src "*.c")
add_executable(stdcrt_test ${test_src})
set_target_properties(stdcrt_test PROPERTIES OUTPUT_NAME "stdcrt_test")
target_link_libraries(stdcrt_test stdcrt)

include_directories(
		${PROJECT_SOURCE_DIR}/nettls
		${PROJECT_SOURCE_DIR}/crt
		${by3rd_library_include})

link_directories (
		${LIBRARY_OUTPUT_PATH})

if (${WIN_OS})
	target_link_libraries(stdcrt_test ws2_32)
else()

	include_directories(
		/usr/local/include
		/opt/local/include
		/usr/include)

	link_directories (
		/usr/local/lib
		/opt/local/lib
		/opt/lib)


	if(ENABLE_FSANITIZE)
		target_link_libraries(stdcrt_test asan)
	endif()
	
	set_target_properties(stdcrt_test PROPERTIES COMPILE_FLAGS ${execute})
	set_target_properties(stdcrt_test PROPERTIES COMPILE_FLAGS ${compile})

endif()











